package br.edu.ufcg.lsd.wbis.ui.client.ui;

import com.gwtext.client.core.EventObject;
import com.gwtext.client.widgets.Button;
import com.gwtext.client.widgets.event.ButtonListenerAdapter;
import com.gwtext.client.widgets.form.FormPanel;

/**
 * @author Renato Miceli
 */
public class ResetButtonListener extends ButtonListenerAdapter {

	private final FormPanel formPanel;

	public ResetButtonListener(FormPanel formPanel) {
		this.formPanel = formPanel;
	}

	@Override
	public void onClick(Button button, EventObject e) {
		this.formPanel.getForm().reset();
	}

}
